import request from 'umi-request';

export async function GetNav() {
  return request('/api/Page/InfoTypeList', { params: { page: 1, limit: 1000 } });
}
export async function GetInfoList(params) {
  return request('/api/Page/InfoList', { params });
}
export async function GetHotList({ limit }) {
  return request('/api/Page/InfoListByHot', { params: { page: 1, limit } });
}
export async function GetNewList({ limit }) {
  return request('/api/Page/InfoListByNew', { params: { page: 1, limit } });
}
export async function GetInfo({ id }) {
  return request('/api/Page/Info', { params: { id } });
}
export async function ReadConfig(params) {
  return request('/api/Page/ReadConfig', {
    method: 'get',
    params,
  })
}
export async function imgcode(params) {
  return request('/api/Page/imgcode', {
    method: 'post',
    data: params,
  })
}
export async function OnlineAddEdit(params) {
  return request('/api/Page/OnlineAddEdit', {
    method: 'post',
    data: params,
  })
}
export async function OnlineAdd(params) {
  return request('/api/Page/OnlineAdd', {
    method: 'post',
    data: params,
  })
}
export async function OnlineQuery(params) {
  return request('/api/Page/OnlineQuery', {
    method: 'post',
    data: params,
  })
}

export async function GuestbookAdd(params) {
  return request('/api/Page/GuestbookAdd', {
    method: 'post',
    data: params,
  })
}

export async function GuestbookList(params) {
  return request('/api/Page/GuestbookList', {
    method: 'post',
    data: params,
  })
}